class FooSearcher{
    static [Symbol.search](target) {
        return target.indexOf('foo');
    };
};